<?php

/**
* 信息提示类
* created by ChenHuaiqi
*/

namespace app\lib\exception;

class ReturnMessage
{
	
	public $msg = 'ok';
	public $errorCode = '0';
	public $data = [];

	public function __construct($params=array()){

		if(!is_array($params)){
			return;
		}

		if(array_key_exists('msg', $params)){
			$this->msg = $params['msg'];
		}

		if(array_key_exists('errorCode', $params)){
			$this->errorCode = $params['errorCode'];
		}

		if(array_key_exists('data', $params)){
			$this->data = $params['data'];
		}
	}
}